<?php
if((gpcGet("gauntlet_logout") || $gauntlet_execute_logout) && isset($_SESSION[CMBASIC]['login'])) {
  if($gauntlet_execute_logout) {
    $glog->add("logoutauto", $_SESSION[CMBASIC]['user']);
  } else {
    $glog->add("logout", $_SESSION[CMBASIC]['user']);
  }
  if(isset($_SESSION[CMBASIC]['login'])){unset($_SESSION[CMBASIC]['login']);}
  if(isset($_SESSION[CMBASIC]['user'])){unset($_SESSION[CMBASIC]['user']);}
  if(isset($_SESSION[CMBASIC]['rights'])){unset($_SESSION[CMBASIC]['rights']);}
  if(isset($_SESSION[CMBASIC]['gauntlet_security'])){unset($_SESSION[CMBASIC]['gauntlet_security']);}
}
?>